package com.itheima.d3_method_references;

/**
 * 目标：掌握特定类型的方法引用。
 */
public class Test3 {
    public static void main(String[] args) {
        B b = new B();
        b.method2(B::method1);

    }


}
@FunctionalInterface
interface A {
    void test(B b, int a, int c);
}

class B {
    public void method1(int a, int b) {
        System.out.println(a + "," + b);
    }

    public void method2(A a) {
        a.test(this, 100, 200);
    }
}